<template>
  <div class="my-container">
    <!-- <img src="@/assets/wap/myBg.png" /> -->
    <div class="cc"></div>
    <div class="mePosition">
      <div class="meMainBox">
        <div class="meHead">
          <div class="meHeadAvatar"><img src="@/assets/wap/avatar.png" /></div>
          <div class="meHeadName"><span>1111111</span></div>
        </div>

        <div class="meOverBg">
          <div class="meVisitor">
            <div class="meVisitorLt">
              <div class="meVisitorTxt_02">
                ￥
                <byui-count
                  :start-val="0"
                  :end-val="5442452"
                  :duration="3000"
                  separator=","
                  :decimals="0"
                />
              </div>
              <div class="meVisitorTxt_01">总业绩</div>
            </div>
            <div class="meVisitorLt">
              <div class="meVisitorTxt_02">
                <byui-count
                  :start-val="0"
                  :end-val="165237"
                  :duration="3000"
                  separator=","
                  :decimals="0"
                />
              </div>
              <div class="meVisitorTxt_01">总跑单量</div>
            </div>
            <div class="meVisitorLt">
              <div class="meVisitorTxt_02">
                ￥
                <byui-count
                  :start-val="0"
                  :end-val="3123"
                  :duration="3000"
                  separator=","
                  :decimals="0"
                />
              </div>
              <div class="meVisitorTxt_01">淘礼金总盈亏</div>
            </div>
          </div>
        </div>

        <div class="meOverBg">
          <div class="meVisitorTitle">今日数据</div>

          <div class="meVisitor">
            <div class="meVisitorLt">
              <div class="meVisitorTxt_02">
                ￥
                <byui-count
                  :start-val="0"
                  :end-val="2452"
                  :duration="3000"
                  separator=","
                  :decimals="0"
                />
              </div>
              <div class="meVisitorTxt_01">业绩量</div>
            </div>
            <div class="meVisitorLt">
              <div class="meVisitorTxt_02">
                <byui-count
                  :start-val="0"
                  :end-val="237"
                  :duration="3000"
                  separator=","
                  :decimals="0"
                />
              </div>
              <div class="meVisitorTxt_01">跑单量</div>
            </div>
            <div class="meVisitorLt">
              <div class="meVisitorTxt_02">
                ￥
                <byui-count
                  :start-val="0"
                  :end-val="-123"
                  :duration="3000"
                  separator=","
                  :decimals="0"
                />
              </div>
              <div class="meVisitorTxt_01">淘礼金盈亏</div>
            </div>
          </div>
        </div>

        <div class="meOverBg">
          <div class="meVisitorTitle">我的订单</div>
          <div class="meVisitor">
            <div class="meOrderLt" @click="open('/myOrder')">
              <div class="meOrderTxt_01">
                <img src="@/assets/wap/taobao.png" />
              </div>
              <div class="meOrderTxt_02">淘宝订单</div>
            </div>
            <div class="meOrderLt">
              <div class="meOrderTxt_01">
                <img src="@/assets/wap/taolijin.png" />
              </div>
              <div class="meOrderTxt_02">礼金订单</div>
            </div>
            <!--div class="meOrderLt">
              <div class="meOrderTxt_01"><img src="@/assets/wap/meIcon_01.png" /></div>
              <div class="meOrderTxt_02">已付款</div>
            </div>
            <div class="meOrderLt">
              <div class="meOrderTxt_01"><img src="@/assets/wap/meIcon_01.png" /></div>
              <div class="meOrderTxt_02">已失效</div>
            </div-->
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
import ByuiCount from "@/plugins/byuiCount";
import { mapGetters } from "vuex";
export default {
  name: "My",
  components: {
    ByuiCount,
  },
  data() {
    return {
      checked: true,
    };
  },
  computed: {
    ...mapGetters(["device"]),
  },
  created() {
    console.log(this.device);
  },
  mounted() {},
  methods: {
    open(url) {
      this.$router.push({ path: url });
    },
  },
};
</script>
<style lang="scss" scoped>
body {
  background: #f5f5f5;
}
.my-container {
  background: #f5f5f5;
  max-width: 480px;
  height: 100vh;
  position: relative;
  margin: 0 auto;
  img {
    width: 100%;
    height: 130px;
    display: block;
  }
  .cc {
    width: 100%;
    height: 160px;
    display: block;
    border-radius: 0 0 300px 300px/0 0 20px 20px;
    background: -webkit-gradient(
      linear,
      left top,
      right top,
      from(#eb3c3c),
      to(#ff7459)
    );
    background: -webkit-linear-gradient(left, #eb3c3c, #ff7459);
    background: -webkit-gradient(
      linear,
      left top,
      right top,
      from(#eb3c3c),
      to(#ff7459)
    );
    background: -webkit-linear-gradient(left, #eb3c3c, #ff7459);
    background: linear-gradient(90deg, #eb3c3c, #ff7459);
  }
  .mePosition {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    .meMainBox {
      width: 92%;
      margin: 0 auto;

      .meHead {
        overflow: hidden;
        position: relative;
        padding-top: 20px;
        .meHeadAvatar {
          float: left;
          width: 19%;
          margin-top: 5px;
          img {
            width: 50px;
            height: 50px;
            display: block;
            border-radius: 50%;
          }
        }
        .meHeadName {
          float: left;
          width: 81%;
          line-height: 60px;
          color: #ffffff;
          font-size: 14px;
          overflow: hidden;
          text-overflow: ellipsis;
          white-space: nowrap;
        }
      }
      .meOverBg {
        background: #ffffff;
        overflow: hidden;
        border-radius: 6px;
        margin-top: 15px;
        .meVisitorTitle {
          font-size: 15px;
          color: #333333;
          border-bottom: 1px #f5f5f5 solid;
          padding: 10px 15px;
        }
        .meVisitor {
          display: flex;
          flex-direction: row;
          .meVisitorLt {
            width: 50%;
            text-align: center;
            margin: 15px 0;
            .meVisitorTxt_01 {
              font-size: 13px;
              color: #666666;
              img {
                width: 20px;
                height: 20px;
                display: block;
                margin: 0 auto 3px;
              }
            }
            .meVisitorTxt_02 {
              font-size: 16px;
              color: #e93b3d;
              font-weight: bold;
              line-height: 30px;
            }
          }
          .meVisitorLt:nth-last-child(1n + 1) {
            border-left: 1px #f5f5f5 solid;
            border-right: 1px #f5f5f5 solid;
          }
          .meOrderLt {
            width: 25%;
            text-align: center;
            padding: 15px 0;
            transition: all 0.4s;
            .meOrderTxt_01 {
              img {
                width: 40px;
                height: 40px;
                display: block;
                margin: 0 auto 3px;
              }
            }
            .meOrderTxt_02 {
              font-size: 13px;
              color: #666666;
              line-height: 18px;
            }
          }
        }
      }
    }
  }
}
</style>
